package com.brillilab.service.core.account;

import java.util.Date;
import java.util.List;

import com.brillilab.domain.enums.account.IntegralStateEnum;
import com.brillilab.domain.enums.account.IntegralTypeEnum;
import com.brillilab.domain.po.account.IntegralRecord;

/**
* 用户积分记录表
* @author LJ
*/
public interface IntegralRecordService {


	IntegralRecord insert(IntegralRecord record);

	List<IntegralRecord> getIntegralRecord(Long userId, IntegralStateEnum integralState);

	int receivedIntegralBatch(Long userId);

	int getUnreceivedIntegral(Long userId);

	void exchangeIntegral(Long userId, Long exchangeId);

	List<IntegralRecord> getIntegralRecordByExchangeId(Long userId, Long exchangeId);

	int receivedIntegral(Long userId, Long recordId);
	
	IntegralRecord getRecord(Long userId, Long recordId);

	List<IntegralRecord> getIntegralRecord(Long userId, IntegralTypeEnum integralType, Date dayBegin, Date dayEnd);

	IntegralRecord getIntegralRecord(Long userId, IntegralTypeEnum integralType, Long dataId);

	List<IntegralRecord> getIntegralRecord(Long userId, IntegralTypeEnum integralType);

	void setInvalid(List<Long> invalidIds);

//	void updateInvalidRecord();

}

